The invention relates to a process for the switching of an MPEG stream, for example a stream of video sequences or programme segments coded according to the MPEG standard, the latter standing for the expression Motion Picture Expert Group.
Coding according to the MPEG standard calls upon various types of coding of the pictures:
intra coding (I picture) making no reference to any previous or following picture,
inter coding of predictive type (P picture) which may call upon a previous reference picture
inter coding of bidirectional type (B picture) which may call upon a previous reference picture and/or a following reference picture.
The pictures, according to the MPEG standard, are grouped together into GOPs or Groups Of Pictures. The first picture of a GOP is a picture of intra type and the first few pictures of B type which follow may call upon pictures of the same GOP, this then being a closed GOP, or else upon pictures of the same GOP and of the previous GOP, this then being an open GOP.
Films or video sequences are nowadays commonly stored in compressed form, so as to reduce the memory capacity required. Switchings of sequences are then performed not in baseband but directly from the MPEG coded data streams.
Let us consider for example a broadcast of two successive video sequences based on digital data stored in compressed form, a first compressed video data stream corresponding to a first picture sequence and termed the old stream, which is replaced, onwards of a given point termed the switching point, with a second compressed video data stream termed the new stream and corresponding to a second picture sequence. The problem arises when the data stream following the switching point commences with an open GOP. This is because the decoding of the compressed pictures of a first GOP of this second stream may require, if this is an open GOP, the utilization of pictures of a previous GOP. As the previous GOP corresponds to a data stream of another sequence, the decoded pictures corresponding to this open GOP will exhibit defects. These defects are generally highly visible and are due to the utilization, for the decoding of these first few pictures of B type of the second sequence, of a different reference picture from the one which was used for coding. This is because the picture blocks constituting the picture or the pictures of the open GOP which were coded in bidirectional mode are inter-coded picture blocks based on a reference picture of P or I type of the previous GOP for the same picture sequence. The decoding of the inter-coded blocks, blocks composed of information regarding residuals or prediction errors, for the first few pictures of bidirectional type after the switching point, will utilize different blocks from those which served in calculating these inter-coded blocks of residuals. The reference picture taken into account at decoding level is in fact different from the one taken into account at coding level.
Very troublesome block effects consisting in the displaying of erroneous picture blocks will therefore appear on the first few pictures of the second sequence.
A solution to this problem exists and is known to be described in the MPEG II standard (Part 1: Systems, appendix K). It involves incorporating, into the system layer, information relating to the possible switching points (referred to as xe2x80x9csplicing pointsxe2x80x9d in the standard) for which the transport stream has favourable characteristics, allowing decoding of the pictures without the abovementioned defects (for example by using closed GOPs). Switching may then be carried out at these points alone. Of course, this information must be incorporated into the data stream right from the time that the pictures are coded and it can no longer be incorporated subsequently other than by carrying out a new decompression and compression of the data.
A permitted switching point, at the start of a GOP, adds a constraint on the coding of the first few pictures of this GOP, which are coded in bidirectional mode, this GOP having to be closed. These pictures may use, as reference pictures, only pictures which follow and can no longer use previous pictures; they are therefore forced into monodirectional mode. This MPEG II coding which is compatible with stream switchings therefore decreases the compression rate and is not normally used for coding films or video sequences. Today, the market contains omly a very small number of products forcing closed GOPs for the switching requirements, the constraints induced in respect of the bit rate regulation at coder level being troublesome. Moreover, a-priori determination of the locations in the data stream at which a closed GOP must exist, that is to say prediction of the locations in the sequence where the cuts will be made, presupposes that the future uses of the sequences are known. Otherwise, it would be necessary to use closed GOPs exclusively.
This solution therefore has several drawbacks:
reduction in the video data compression rate
requirement for decoding and recoding in respect of data streams not possessing this compatibility of stream switching at the outset, with all the problems related to restorage, to picture quality etc.
The aim of the invention is to alleviate the aforesaid drawbacks.
The subject of the invention is an MPEG stream switching process for transmitting a first data stream corresponding to a first video sequence followed, at a given point of switching of this first stream, by a second data stream corresponding to a second video sequence, each sequence being coded according to a GOP (Group Of Pictures) structure, each GOP comprising pictures of intra-coded intra type, of inter-coded predictive type and of inter-coded bidirectional type, each picture coding corresponding to a coding cost dependent on the amount of information to be transmitted in the data stream for the coding of this picture, the switching point being at the level of a GOP, characterized in that the second data stream is modified before transmission, by replacing coding information for the first inter pictures of bidirectional type following the intra picture of the first GOP of the second sequence after the switching point, when considering the order of coding of the pictures, with predefined picture coding information whose coding cost is less than or equal to that of the initial pictures.
The main advantage of the invention is that it allows switching from one video sequence over to another sequence or insertion of one video sequence into another sequence while minimizing the defects which may appear during the switching or switchings. By virtue of the invention, it is possible to utilize MPEG coded data streams which are not compatible with stream switching (open GOPs), and hence optimally compressed video sequences.
The sequence transitions are softened by eliminating the most troublesome picture defects generated by the open GOPs at the start of the new data stream.
The switchings may be performed in a random manner, for example by random access to data stored on magnetic disks, the coded data streams not being subjected to any particular configuring before and after a switching point.
The cost of implementation is minimal since the structure of the transport stream is not modified by the processing, avoiding complex operations of depacketization and repacketization.